#ifndef CELL_H
#define CELL_H

#include <QList>
#include <QPolygonF>

#include "node.h"
#include "edge.h"
#include "area.h"

//! Cell model. Base model structure.
/*!
  CELL contains the whole description of the model at the moment.
  */
struct CELL
{
    explicit CELL(void);
    QList<NODE> nodes; //!< List of all nodes of the model.
    QList<EDGE> edges; //!< List of all edges of the model.
    QList<AREA> areas; //!< List of all areas of the model.

    QPolygonF fCPosPolygon; //!< Trace of the frontal nodes geometric center.
    QPointF cPos;           //!< All nodes geometric center position.
    QPointF fCPos;          //!< Frontal nodes geometric centre position.

    int boundaryNodesCount; //!< Number of boundary nodes.
    int frontNodesCount; //!< Number of frontal nodes.

    double area;     //!< Current cell area.
    double beta;     //!< Proportional coefficient in the b*exp(-(xfront-x)/(beta*(xfront-xrear)) contractile force distribution.
    double dt;       //!< Time step, [seconds].
    double eMax;     //!< Maximal Young's modulus in distribution, [newton/meter^2].
    double eMin;     //!< Minimal Young's modulus in the distribution, [newton/meter^2].
    double fpol;     //!< Polymerization force per node, [newton].
    double fadh;     //!< Adhesion force per node, [newton].
    double fcon;     //!< Total contraction force, [newton].
    double gamma;    //!< Proportional coefficient in the b*exp(-(xfront-x)/(gamma*(xfront-xrear)) adhesion force distribution.
    double h;        //!< Cell's height, [meter].
    double mu;       //!< Viscosity [newton*second/meter^2].
    double scale;    //!< Pixels per micrometer.
    double sigma;    //!< Default substrate stiffness, [newton/meter^2].
    double sigmaAV;  //!< sigma_{av} from Irina's article, [newton/meter^2].
    double t;        //!< Total model calculation time, [second].
    double velocity; //!< Current cell velocity, [micrometer/min].
};

#endif // CELL_H
